/* 全局样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 头部样式 */
header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 60px 0;
    text-align: center;
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    font-weight: 700;
}

header p {
    font-size: 1.2rem;
    opacity: 0.9;
}

/* 主要内容样式 */
main {
    padding: 40px 0;
}

/* 添加记录区域 */
.add-entry {
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    padding: 30px;
    margin-bottom: 40px;
}

.add-entry h2 {
    margin-bottom: 20px;
    color: #667eea;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #555;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 16px;
    transition: border-color 0.3s;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: #667eea;
}

.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-primary {
    background-color: #667eea;
    color: white;
}

.btn-primary:hover {
    background-color: #5a5fd8;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

/* 记录列表区域 */
.entries {
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    padding: 30px;
}

.entries h2 {
    margin-bottom: 20px;
    color: #667eea;
}

.search-filter {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
}

.search-filter input,
.search-filter select {
    flex: 1;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 16px;
}

.entries-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 20px;
}

.entry-card {
    background-color: #f9f9f9;
    border-radius: 8px;
    padding: 20px;
    border-left: 4px solid #667eea;
    transition: transform 0.3s, box-shadow 0.3s;
}

.entry-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.entry-card h3 {
    margin-bottom: 10px;
    color: #333;
}

.entry-card .date {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 10px;
}

.entry-card .mood {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    margin-bottom: 10px;
}

.mood.happy { background-color: #e3f2fd; color: #1976d2; }
.mood.excited { background-color: #fff8e1; color: #ff8f00; }
.mood.calm { background-color: #e8f5e9; color: #388e3c; }
.mood.sad { background-color: #eeeeee; color: #616161; }
.mood.tired { background-color: #f3e5f5; color: #7b1fa2; }

.entry-card .content {
    color: #555;
    margin-bottom: 15px;
    line-height: 1.5;
}

.entry-card .actions {
    display: flex;
    gap: 10px;
}

.btn-secondary {
    background-color: #f0f0f0;
    color: #666;
    padding: 8px 16px;
    font-size: 14px;
}

.btn-secondary:hover {
    background-color: #e0e0e0;
}

.btn-danger {
    background-color: #f44336;
    color: white;
    padding: 8px 16px;
    font-size: 14px;
}

.btn-danger:hover {
    background-color: #d32f2f;
}

/* 空状态 */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #999;
}

.empty-state h3 {
    margin-bottom: 10px;
    color: #666;
}

/* 页脚样式 */
footer {
    background-color: #333;
    color: white;
    text-align: center;
    padding: 20px 0;
    margin-top: 40px;
}

footer p {
    opacity: 0.8;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .search-filter {
        flex-direction: column;
    }
    
    .entries-grid {
        grid-template-columns: 1fr;
    }
    
    header h1 {
        font-size: 2rem;
    }
}